home *** CD-ROM | disk | FTP | other *** search
/ PC Player 2004 May / pc player 2004-05.iso / Demos / FarCry / Data1.cab / _5C40B5A4B5BD4B07B6B6C5DACD31FFD4 < prev    next >
Encoding:
Text File  |  2004-01-06  |  2.2 KB  |  87 lines

  1. ; Shaders Script file
  2. ; Copyright (c) 2001-2003 Crytek Studios. All Rights Reserved.
  3. ; Author: Honich Andrey
  4.  
  5. Version (1.00)
  6.  
  7. //========================================================================
  8. // ATI R3xx / NVidia NV3X (PS.2.0 / PS.2.X only)
  9.  
  10. // Specular & Diffuse bump-mapping with real-time env. CM reflections masked by gloss-map (alpha channel of diffuse texture)
  11. // and with specular exp. in alpha channel of gloss texture
  12. // At least two passes for multiple light sources
  13. // One pass for single light source
  14.  
  15. // Supports:
  16. // 1. Dot3 light maps
  17. // 2. Simple light maps
  18. // 3. Three types of shadow maps (2D, Depth-maps and mixed Depth/2D)
  19. // 4. Stencil shadows
  20. // 5. Three types of light sources (Directional, Point/Omni, Projected)
  21. // 6. Optimised separate techniques for Single/Multiple light sources
  22.  
  23. /*Shader 'TemplBumpSpec_GlossAlpha_EnvCMAmb_RT_PowerGlossAlpha_PS20'
  24. (
  25.   Params
  26.   (
  27.     Sort = Opaque
  28.   )
  29.   Public
  30.   (
  31.     float 'ReflectAmount' (0.25)
  32.     float 'SpecularExpMultiplier' (255)
  33.   )
  34.   RenderParams
  35.   {
  36.     DrawFarSprites
  37.     DrawStaticObjects
  38.     DrawParticles
  39.     DrawEntities
  40.     DrawIndoors
  41.     DrawDetailTextures
  42.     FullDetailTerrain
  43.     DrawWater
  44.     DrawTerrain
  45.   }
  46.   
  47.   #define $ENVCMAP $EnvironmentCubeMap
  48.   #include "BumpSpecular_GlossAlpha_EnvCM_PowerGlossAlpha_PS20.csi"  
  49.   #undefine $ENVCMAP
  50. )*/
  51.  
  52. Shader 'TemplBumpSpec_GlossAlpha_EnvCMAmb_RT_PowerGlossAlpha_PS20'
  53. (
  54.   Params
  55.   (
  56.     Sort = Opaque
  57.   )
  58.  
  59.   #define %DIFFUSE 0x1
  60.   #define %DIFFUSE_PERPIXEL 0x8000
  61.   #define %SPECULAR 0x2
  62.   #define %SPECULAR_PERPIXEL 0x400
  63.   #define %BUMP_NORMALIZE 0x200
  64.   #define %ENVCMAMB 0x40
  65.   #define %GLOSS_DIFFUSEALPHA 0x20
  66.   #define %SPECULARPOW_GLOSSALPHA 0x800
  67.   #define %PROJLIGHT_PERPIXELATTEN 0x100
  68.   #define %RTCUBEMAP 0x10000
  69.   #define %BUMP_MAP 0x1000
  70.   
  71.   #include "IllumTemplate.csi"
  72.   
  73.   #undefine %BUMP_MAP
  74.   #undefine %RTCUBEMAP
  75.   #undefine %PROJLIGHT_PERPIXELATTEN
  76.   #undefine %SPECULARPOW_GLOSSALPHA
  77.   #undefine %GLOSS_DIFFUSEALPHA
  78.   #undefine %ENVCMAMB
  79.   #undefine %BUMP_NORMALIZE
  80.   #undefine %SPECULAR_PERPIXEL
  81.   #undefine %SPECULAR
  82.   #undefine %DIFFUSE_PERPIXEL
  83.   #undefine %DIFFUSE
  84. )
  85.  
  86.  
  87.